package com.wsx.ones.monitor.core.serialize;

/**
 * 系统中使用的协议选择
 * Created by wangshuaixin on 17/2/6.
 */
public class ProtocolSelecter {

    public static RpcSerializeProtocol getProtocol(String value) {
        RpcSerializeProtocol[] protocols = RpcSerializeProtocol.values();
        for (RpcSerializeProtocol protocol : protocols) {
            if (value.equals(protocol.getProtocol())) {
                return protocol;
            }
        }
        return RpcSerializeProtocol.HESSIONSERIALIZE;
    }
}
